#pragma GCC optimize(2)
#include <iostream>
#include <algorithm>
#include <cstring>
#include <string>
#include <map>
#include <vector>

using namespace std;
using LL = long long;

void solve(){
    int n;
    int lx = 0, rx = 0, ty = 0, dy = 0;
    cin >> n;

    for(int i = 1, x, y; i <= n; i ++){
        cin >> x >> y;

        lx = min(lx, x);
        rx = max(rx, x);
        ty = min(ty, y);
        dy = max(dy, y);
    }

    LL res = 0;
    res = abs(lx) * 2 + abs(rx) * 2 + abs(ty) * 2 + abs(dy) * 2;
    cout << res << '\n';

}

int main(){
    freopen("in.txt", "r", stdin);
    freopen("out.txt", "w", stdout);
    ios::sync_with_stdio(false);
    cin.tie(nullptr);

    int T;
    cin >> T;
    while(T--){
        solve();
    }


    return 0;
}